﻿@using OpenReservation.Helpers
<!DOCTYPE html>
<html lang="zh-cn">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>@ViewBag.Title - </title>
    @RenderSection("styles", required: false)
</head>
<body>
    <div class="navbar navbar-inverse navbar-fixed-top">
        <div class="container">
            <div class="navbar-header">
                <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                </button>
                @Html.ActionLink("系统管理后台", "Index", "Home", new { area = "Admin" }, new { @class = "navbar-brand" })
            </div>
            <div class="navbar-collapse collapse">
                <ul class="nav navbar-nav">
                    <li>@Html.ActionLink("预约", "Reservate", "ReservationManage")</li>
                    <li>@Html.ActionLink("预约管理", "Index", "ReservationManage")</li>
                    <li>@Html.ActionLink("黑名单管理", "Index", "BlockEntity")</li>
                </ul>
                <ul class="nav navbar-nav navbar-right">
                    @if (!User.Identity.IsAuthenticated)
                    {
                        <li>
                            <a href="/Admin/Account/Login">登录</a>
                        </li>
                    }
                    else
                    {
                        <li class="dropdown">
                            <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">
                                @(User.Identity.Name) <span class="caret"></span>
                            </a>
                            <ul class="dropdown-menu">
                                <li>@Html.ActionLink("我的账户", "Index", "Account")</li>
                                <li role="separator" class="divider"></li>
                                <li>@Html.ActionLink("退出登录", "Logout", "Account")</li>
                            </ul>
                        </li>
                    }
                </ul>
            </div>
        </div>
    </div>
    <div class="container body-content">
        <div class="main-content">
            @RenderBody()
        </div>
        <hr />
        <footer>
            <p>&copy; @DateTime.UtcNow.Year - </p>
        </footer>
    </div>
    <script src="~/Content/layer/layer.js"></script>
    @RenderSection("scripts", required: false)
</body>
</html>